{% extends "project/database_clusters/_detail_overview.html" %}
{% load i18n sizeformat %}

{% block connection_info %}
<div class="addresses row detail">
    <h4>{% trans "Connection Information" %}</h4>
    <hr class="header_rule">
    <dl>
        {% with cluster.ip.0 as ip %}
            <dt>{% trans "Host" %}</dt>
            <dd>
            {% if not ip %}
                {% trans "Not Assigned" %}
            </dd>
            {% else %}
                {{ ip }}
            </dd>
            <dt>{% trans "Database Port" %}</dt>
            <dd>27017</dd>
            <dt>{% trans "Connection Examples" %}</dt>
            <dd>mongo --host {{ ip }}</dd>
            <dd>mongodb://[{% trans "USERNAME" %}:{% trans "PASSWORD" %}@]{{ ip }}:27017/{% trans "DATABASE" %}</dd>
            {% endif %} <!-- ends else block -->
        {% endwith %}
    </dl>
</div>
{% endblock %}
